package com.taxi.remote;

import com.taxi.dto.PriceRule;
import com.taxi.result.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient("service-price")
public interface ServicePriceClient {
    @GetMapping("/price-rule/list")
    public Result getRulesList(@RequestParam int page, @RequestParam int limit, @RequestParam(required=false) String cityCode);

    @PostMapping("/price-rule/add")
    public Result add(@RequestBody PriceRule priceRule);

    @PostMapping("/price-rule/edit")
    public Result edit(@RequestBody PriceRule priceRule);
}
